package com.yegs.jltqc.dao;

import com.yegs.jltqc.VO.QcProduce;
import com.yegs.jltqc.VO.Supplier;
import com.yegs.jltqc.VO.WorkFlow;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.stereotype.Repository;

@Repository
public interface WorkFlowRepository extends JpaRepository<WorkFlow,Long> {

    Page<WorkFlow> findWorkFlowByWorkName(String name, Pageable pageable);

    Page<WorkFlow> findWorkFlowByWorkNameAndStatus(String name, String status, Pageable pageable);

    Page<WorkFlow> findWorkFlowsByStatus(String status, Pageable pageable);

    WorkFlow findFirstByIdIsAfter(Long id);

    WorkFlow findFirstByIdBeforeOrderByIdDesc(Long id);

    WorkFlow findFirstByOrderById();

    WorkFlow findFirstByOrderByIdDesc();


}
